
using System.Data.Entity.ModelConfiguration;

namespace OBUCare.Core.Models.Mapping
{
    public class REPAIR_ORDER_TRACKINGMap : EntityTypeConfiguration<REPAIR_ORDER_TRACKING>
    {
        public REPAIR_ORDER_TRACKINGMap()
        {
            // Primary Key
            this.HasKey(t => t.ID);

            // Properties
            this.Property(t => t.Operator_NO)
                .IsRequired()
                .IsFixedLength()
                .HasMaxLength(6);

            this.Property(t => t.REMARK)
                .HasMaxLength(500);

            // Table & Column Mappings
            this.ToTable("REPAIR_ORDER_TRACKING");
            this.Property(t => t.ID).HasColumnName("ID");
            this.Property(t => t.REPAIR_ORDER_ID).HasColumnName("REPAIR_ORDER_ID");
            this.Property(t => t.Operator_NO).HasColumnName("Operator_NO");
            this.Property(t => t.REPAIR_ORDER_Status).HasColumnName("REPAIR_ORDER_Status");
            this.Property(t => t.REMARK).HasColumnName("REMARK");
            this.Property(t => t.CREATED_DATE).HasColumnName("CREATED_DATE");
        }
    }
}
